import Vue from 'vue'
import Vuex from 'vuex'
Vue.use(Vuex)

export default function (/* { ssrContext } */) {
  const Store = new Vuex.Store({
    state: {
      data: null
    },
    mutations: {
      updateData: (state, payload) => {
        state.data = payload;
      }
    },
    strict: process.env.DEV
  })

  return Store
}
